package cc.autoapi.pucong.auto.flow.provider.sys.service;


import cc.autoapi.pucong.auto.flow.provider.sys.entity.SysReturnUrl;
import cc.autoapi.pucong.auto.flow.provider.sys.entity.UserLoginVo;
import cc.autoapi.pucong.auto.flow.core.root.entity.UserJwt;

import javax.servlet.http.HttpServletRequest;

public interface SysLoginService {

    /**
     * 是否登录
     * @return
     */
    Boolean isLogin(HttpServletRequest request);

    /**
     * 获取登录用户
     * @return
     */
    UserJwt getLoginUser(HttpServletRequest request);

    /**
     * 登录
     * @param userLoginVo
     * @return
     */
    UserJwt login(UserLoginVo userLoginVo);

    /**
     * 退出登录
     */
    SysReturnUrl loginOut(HttpServletRequest request);


    String createToken(UserJwt userJwt);
}
